package com.pojo;

import java.io.Serializable;
import java.util.List;

public class Order<Product> {


    /**
     *
     * @TableName tb_orders
     */
    public class Orders implements Serializable {
        /**
         *
         */
        private Integer id;

        /**
         *
         */
        private String number;

        public List<Product> getProductList() {
            return productList;
        }

        public void setProductList(List<Product> productList) {
            this.productList = productList;
        }

        private List<Product> productList;

        private static final long serialVersionUID = 1L;

        /**
         *
         */
        public Integer getId() {
            return id;
        }

        /**
         *
         */
        public void setId(Integer id) {
            this.id = id;
        }

        /**
         *
         */
        public String getNumber() {
            return number;
        }

        /**
         *
         */
        public void setNumber(String number) {
            this.number = number;
        }


        @Override
        public boolean equals(Object that) {
            if (this == that) {
                return true;
            }
            if (that == null) {
                return false;
            }
            if (getClass() != that.getClass()) {
                return false;
            }
            Orders other = (Orders) that;
            return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
                    && (this.getNumber() == null ? other.getNumber() == null : this.getNumber().equals(other.getNumber()));
        }

        @Override
        public int hashCode() {
            final int prime = 31;
            int result = 1;
            result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
            result = prime * result + ((getNumber() == null) ? 0 : getNumber().hashCode());
            return result;
        }

        @Override
        public String toString() {
            StringBuilder sb = new StringBuilder();
            sb.append(getClass().getSimpleName());
            sb.append(" [");
            sb.append("Hash = ").append(hashCode());
            sb.append(", id=").append(id);
            sb.append(", number=").append(number);
            sb.append(", productList=").append(productList);
            sb.append(", serialVersionUID=").append(serialVersionUID);
            sb.append("]");
            return sb.toString();
        }
    }
}
